package com.blog.login.mapper;

import com.blog.login.entity.Role;
import com.blog.login.entity.User;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author 苏离
 * @since 2021-12-08
 */
public interface UserMapper extends BaseMapper<User> {

    String findUserByName(String name);

    User getUser(String name);

    List<String> getUserRole(String userId);

    Integer updateUserPassword(@Param("username") String username,
                               @Param("password") String password,
                               @Param("salt") String salt);

}
